﻿// My methods here.
//-----------------------------------------------------------------------
// <Copyright file=LoaiKhuyenMaiAndKhuyenMai company=DHPD>
// Copyright (c) DHPD Corporation (http://dhpd.edu.vn). All rights reserved.
// </copyright>
// <author>HP</author>
//-----------------------------------------------------------------------


using System;
using System.Collections.Generic;
using KM.DAT;
using KM.ENT;
using KM.Models;

namespace KM.BUS
{
    /// <summary>
    /// This is busLoaiKhuyenMaiAndKhuyenMai class
    /// </summary>

    public class busLoaiKhuyenMaiAndKhuyenMai
    {
        public busLoaiKhuyenMaiAndKhuyenMai()
        {
            //
            // TODO: Add constructor logic here
            //
        }
        public void createEdit(entLoaiKhuyenMaiAndKhuyenMai entLKMAKM)
        {
            datLoaiKhuyenMaiAndKhuyenMai datLKMAKM = new datLoaiKhuyenMaiAndKhuyenMai();
            datLKMAKM.createEdit(entLKMAKM);
        }
        public List<entLoaiKhuyenMaiAndKhuyenMai> getAll(ref PagingInfoModel page)
        {
            datLoaiKhuyenMaiAndKhuyenMai datLKMAKM = new datLoaiKhuyenMaiAndKhuyenMai();
            List<entLoaiKhuyenMaiAndKhuyenMai> lst = new List<entLoaiKhuyenMaiAndKhuyenMai>();
            lst = datLKMAKM.getAll(ref page);
            return lst;
        }
        public List<entLoaiKhuyenMaiAndKhuyenMai> getAllByForeignKey(int Id, ref PagingInfoModel page)
        {
            datLoaiKhuyenMaiAndKhuyenMai datLKMAKM = new datLoaiKhuyenMaiAndKhuyenMai();
            List<entLoaiKhuyenMaiAndKhuyenMai> lst = new List<entLoaiKhuyenMaiAndKhuyenMai>();
            lst = datLKMAKM.getAllByForeignKey(Id, ref page);
            return lst;
        }
        public entLoaiKhuyenMaiAndKhuyenMai getInfo(int Id)
        {
            datLoaiKhuyenMaiAndKhuyenMai datLKMAKM = new datLoaiKhuyenMaiAndKhuyenMai();
            entLoaiKhuyenMaiAndKhuyenMai entLKMAKM = new entLoaiKhuyenMaiAndKhuyenMai();
            entLKMAKM = datLKMAKM.getInfo(Id);
            return entLKMAKM;
        }
        public bool delete(int Id)
        {
            datLoaiKhuyenMaiAndKhuyenMai datLKMAKM = new datLoaiKhuyenMaiAndKhuyenMai();
            datLKMAKM.delete(Id);
            return true;
        }
    }
}
